package com.engr.lyx.common.exception;

/**
 * @program: blog
 * @desc: 自定义异常
 * @author: lyx
 * @date: 2019-05-15 17:40
 **/
public class ServiceException extends RuntimeException{

    private Integer code;

    public ServiceException(Integer code, String message, Throwable cause) {
        super(message, cause);
        this.code = code;
    }

    public ServiceException(Integer code,String message) {
        super(message);
        this.code = code;
    }

    public ServiceException(String message) {
        super(message);
    }


    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }
}
